package com.jiuqi.ccp.generator.dao.pojo;

import java.io.Serializable;
import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;

/** 
 *        @hibernate.class
 *         table="CCP_GCM_MSGPURVIEW"
 *     
*/
public class CcpGcmMsgpurview implements Serializable {

    /** identifier field */
    private String purviewGuid;

    /** nullable persistent field */
    private String typeCode;

    /** persistent field */
    private String orgorusrGuid;

    /** nullable persistent field */
    private String purviewType;

    /** persistent field */
    private String msgorcatGuid;

    /** nullable persistent field */
    private String readFlag;

    /** nullable persistent field */
    private String reserved1;

    /** nullable persistent field */
    private String reserved2;

    /** nullable persistent field */
    private String reserved3;

    /** full constructor */
    public CcpGcmMsgpurview(String purviewGuid, String typeCode, String orgorusrGuid, String purviewType, String msgorcatGuid, String readFlag, String reserved1, String reserved2, String reserved3) {
        this.purviewGuid = purviewGuid;
        this.typeCode = typeCode;
        this.orgorusrGuid = orgorusrGuid;
        this.purviewType = purviewType;
        this.msgorcatGuid = msgorcatGuid;
        this.readFlag = readFlag;
        this.reserved1 = reserved1;
        this.reserved2 = reserved2;
        this.reserved3 = reserved3;
    }

    /** default constructor */
    public CcpGcmMsgpurview() {
    }

    /** minimal constructor */
    public CcpGcmMsgpurview(String purviewGuid, String orgorusrGuid, String msgorcatGuid) {
        this.purviewGuid = purviewGuid;
        this.orgorusrGuid = orgorusrGuid;
        this.msgorcatGuid = msgorcatGuid;
    }

    /** 
     *            @hibernate.id
     *             generator-class="assigned"
     *             type="java.lang.String"
     *             column="PURVIEW_GUID"
     *         
     */
    public String getPurviewGuid() {
        return this.purviewGuid;
    }

    public void setPurviewGuid(String purviewGuid) {
        this.purviewGuid = purviewGuid;
    }

    /** 
     *            @hibernate.property
     *             column="TYPE_CODE"
     *             length="2"
     *         
     */
    public String getTypeCode() {
        return this.typeCode;
    }

    public void setTypeCode(String typeCode) {
        this.typeCode = typeCode;
    }

    /** 
     *            @hibernate.property
     *             column="ORGORUSR_GUID"
     *             length="50"
     *             not-null="true"
     *         
     */
    public String getOrgorusrGuid() {
        return this.orgorusrGuid;
    }

    public void setOrgorusrGuid(String orgorusrGuid) {
        this.orgorusrGuid = orgorusrGuid;
    }

    /** 
     *            @hibernate.property
     *             column="PURVIEW_TYPE"
     *             length="50"
     *         
     */
    public String getPurviewType() {
        return this.purviewType;
    }

    public void setPurviewType(String purviewType) {
        this.purviewType = purviewType;
    }

    /** 
     *            @hibernate.property
     *             column="MSGORCAT_GUID"
     *             length="32"
     *             not-null="true"
     *         
     */
    public String getMsgorcatGuid() {
        return this.msgorcatGuid;
    }

    public void setMsgorcatGuid(String msgorcatGuid) {
        this.msgorcatGuid = msgorcatGuid;
    }

    /** 
     *            @hibernate.property
     *             column="READ_FLAG"
     *             length="1"
     *         
     */
    public String getReadFlag() {
        return this.readFlag;
    }

    public void setReadFlag(String readFlag) {
        this.readFlag = readFlag;
    }

    /** 
     *            @hibernate.property
     *             column="RESERVED1"
     *             length="50"
     *         
     */
    public String getReserved1() {
        return this.reserved1;
    }

    public void setReserved1(String reserved1) {
        this.reserved1 = reserved1;
    }

    /** 
     *            @hibernate.property
     *             column="RESERVED2"
     *             length="50"
     *         
     */
    public String getReserved2() {
        return this.reserved2;
    }

    public void setReserved2(String reserved2) {
        this.reserved2 = reserved2;
    }

    /** 
     *            @hibernate.property
     *             column="RESERVED3"
     *             length="100"
     *         
     */
    public String getReserved3() {
        return this.reserved3;
    }

    public void setReserved3(String reserved3) {
        this.reserved3 = reserved3;
    }

    public String toString() {
        return new ToStringBuilder(this)
            .append("purviewGuid", getPurviewGuid())
            .toString();
    }

    public boolean equals(Object other) {
        if ( !(other instanceof CcpGcmMsgpurview) ) return false;
        CcpGcmMsgpurview castOther = (CcpGcmMsgpurview) other;
        return new EqualsBuilder()
            .append(this.getPurviewGuid(), castOther.getPurviewGuid())
            .isEquals();
    }

    public int hashCode() {
        return new HashCodeBuilder()
            .append(getPurviewGuid())
            .toHashCode();
    }

}
